package com.mc.jf.utils;

import org.springframework.http.HttpStatus;

import javax.servlet.http.HttpServletResponse;

public class WebUtils {

    public static String renderString(HttpServletResponse response,String string){
        try {
            response.setStatus(HttpStatus.OK.value());
            response.setContentType("application/json");
            response.setCharacterEncoding("utf-8");
            response.getWriter().write(string);
        }catch (Exception e){
            e.printStackTrace();
        }
        return null;
    }

}
